package com.ganlebao.study.springcloudribbon.basic.acl;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

import static com.ganlebao.study.springcloudribbon.SpringCloudRibbonApplication.ECHO_SERVER;

@FeignClient(name = ECHO_SERVER)
public interface EchoServer {

    /**
     * 简单echo
     *
     * @param value
     * @return
     */
    @GetMapping("echo")
    String echo(@RequestParam("value") String value);

    /**
     * 接口带超时
     *
     * @param value
     * @return
     */
    @GetMapping("echo-timeout")
    String echoWithTimeout(@RequestParam("value") String value);
}
